/**
 * 
 */
package org.droid.cmplatform.core.task;

import org.droid.cmplatform.core.constant.Constant;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteDatabase.CursorFactory;
import android.database.sqlite.SQLiteOpenHelper;
import android.util.Log;

/**
 * @author Karen [Email:keyu404@gmail.com]
 * 
 */
public class TaskDBHelper extends SQLiteOpenHelper {
    private static final int VERSION = 1;
    private static final String TAG = "";
    private static final String DB_NAME = "task_droid_db";

    private static final String SQL_CREATE_DB = "";

    /**
     * @param context
     * @param factory
     * @see SQLiteOpenHelper#SQLiteOpenHelper(Context, String, CursorFactory, int)
     */
    public TaskDBHelper(Context context, CursorFactory factory) {
        super(context, DB_NAME, factory, VERSION);
    }

    /**
     * 
     * @param context
     * @see TaskDBHelper#TaskDBHelper(Context, CursorFactory)
     */
    public TaskDBHelper(Context context) {
        this(context, null);
    }

    /*
     * (non-Javadoc)
     * @see
     * android.database.sqlite.SQLiteOpenHelper#onCreate(android.database.sqlite.SQLiteDatabase)
     */
    @Override
    public void onCreate(SQLiteDatabase db) {
        if (Constant.DEBUG) {
            Log.d(TAG, "onCreate =>> create db");
        }
        db.execSQL(SQL_CREATE_DB);
    }

    /*
     * (non-Javadoc)
     * @see
     * android.database.sqlite.SQLiteOpenHelper#onUpgrade(android.database.sqlite.SQLiteDatabase,
     * int, int)
     */
    @Override
    public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
        
    }
}
